package com.greysh.enter.dao;

import java.sql.SQLException;
 

import org.springframework.orm.ibatis.support.SqlMapClientDaoSupport;

import com.greysh.enter.model.Admin;
 

public class AdminDao extends SqlMapClientDaoSupport {

 

	// 删除考试
	public void deleteTest(int id) throws SQLException {
		getSqlMapClientTemplate().delete("deleteTestById", id);
	}

	 

	// 删除考生成绩
	public void deleteScore(int id) throws SQLException {
		getSqlMapClientTemplate().delete("deleteScoreById", id);
	}

	 
	// 按用户名查询密码
	public Admin selectAdminByName(String name) throws SQLException {
		return (Admin) getSqlMapClientTemplate().queryForObject(
				"selectAdminByName", name);
	}

	 
}
